[ykj_id].vue 7.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283
  1. <template>
  2. <div class="cjfx_slyf">
  3. <NavHeader />
  4. <bread-crumb />
  5. <div class="w-1200px m-auto flex flex-row justify-between">
  6. <div class="w-188px">
  7. <leftSider :ykjId="ykjId" :activeIndex="activeIndex" @parentClick="parentClick"/>
  8. </div>
  9. <div class="w-1012px p-4 overflow-visible blueBg">
  10. <div class="flex items-center">
  11. <optionSelect @optionClick="optionClick" />
  12. </div>
  13. <div class="w-270px searchBtn" @click="handleSearch">
  14. <el-input v-model="searchVal" class="w-50 mt-2 h-auto" placeholder="请输入搜索内容" />
  15. <div class="w-26px h-26px rounded searchBtnIcon">
  16. <img src="/images/searchBtnIcon.png" alt="">
  17. </div>
  18. </div>
  19. <div class="flex justify-between mt-4 exportBtn">
  20. <div>
  21. <el-button color="#003eee" type="primary" size="large" @click="restBtn">重置</el-button>
  22. <el-button color="#003eee" type="primary" size="large" @click="exportBtn">导出</el-button>
  23. </div>
  24. <div>
  25. <el-button color="#003eee" type="primary" size="large" @click="openDialog">校三率一分</el-button>
  26. </div>
  27. </div>
  28. <div class="h-auto mt-9px listMain">
  29. <el-table :data="tableData" style="width: 100%">
  30. <el-table-column prop="xx" label="学校" show-overflow-tooltip width="200" />
  31. <el-table-column prop="bj" label="班级" width="120" />
  32. <el-table-column prop="pm" label="排名" />
  33. <el-table-column prop="pjf" label="平均分" />
  34. <el-table-column prop="ykrs" label="应考人数" />
  35. <el-table-column prop="skrs" label="实考人数" />
  36. <el-table-column prop="zgf" label="最高分" />
  37. <el-table-column prop="yxrs" label="优秀人数" />
  38. <el-table-column prop="yxl" label="优秀率" />
  39. <el-table-column prop="jgrs" label="及格人数" />
  40. <el-table-column prop="jgl" label="及格率" />
  41. <el-table-column prop="dfrs" label="低分人数" />
  42. <el-table-column prop="dfl" label="低分率" />
  43. <el-table-column prop="nd" label="难度" />
  44. <el-table-column prop="qfd" label="区分度" />
  45. <el-table-column prop="bzc" label="标椎差" />
  46. </el-table>
  47. <div class="mt-4" >
  48. <el-pagination background layout="prev, pager, next " :total="totalPage" style="justify-content: right;" />
  49. </div>
  50. </div>
  51. </div>
  52. <!-- dialog -->
  53. <el-dialog v-model="dialogTableVisible" title="校三率一分" style="width: 90%;">
  54. <el-table :data="tableData" style="width: 100%;">
  55. <el-table-column prop="xx" label="学校" show-overflow-tooltip />
  56. <el-table-column prop="ksrs" label="考试人数"/>
  57. <el-table-column prop="skrs" label="实考人数"/>
  58. <el-table-column prop="zgf" label="最高分"/>
  59. <el-table-column prop="pjf" label="平均分"/>
  60. <el-table-column prop="pjfpm" label="平均分排名"/>
  61. <el-table-column prop="pjfdf" label="平均分(得分)"/>
  62. <el-table-column prop="yxl" label="优秀率"/>
  63. <el-table-column prop="yxlpm" label="优秀率排名"/>
  64. <el-table-column prop="yxldf" label="优秀率得分(30%)"/>
  65. <el-table-column prop="jgl" label="及格率"/>
  66. <el-table-column prop="jglpm" label="及格率排名"/>
  67. <el-table-column prop="jgldf" label="及格率得分(30%)"/>
  68. <el-table-column prop="dfrs" label="低分人数"/>
  69. <el-table-column prop="dfl" label="低分率"/>
  70. <el-table-column prop="zdf" label="总得分(100)"/>
  71. <el-table-column prop="zpm" label="总排名"/>
  72. <el-table-column prop="nd" label="难度"/>
  73. <el-table-column prop="qfd" label="区分度"/>
  74. <el-table-column prop="bzc" label="标准差 "/>
  75. </el-table>
  76. <template #footer>
  77. <span class="dialog-footer">
  78. <el-button type="primary" color="#003eee" @click="dialogTableVisible = false">关闭</el-button>
  79. </span>
  80. </template>
  81. </el-dialog>
  82. </div>
  83. <commonFooter />
  84. </div>
  85. </template>
  86. <route lang="json">
  87. {
  88. "meta": {
  89. "title": "考试分析",
  90. "breadcrumb": true
  91. }
  92. }
  93. </route>
  94. <script lang="ts" setup>
  95. import {cjfx_slyf_list } from '../apiItem';
  96. const route = useRoute();
  97. import {user} from "~/store";
  98. // 侧边栏点击
  99. const activeIndex =ref('1-2');
  100. const ykjId = ref();
  101. const parentClick = (val) => {
  102. activeIndex.value = val;
  103. ykjId.value = route.params.ykj_id;
  104. }
  105. const searchVal = ref();
  106. const tableData = ref([]);
  107. const totalPage = ref();
  108. const pageNum = ref(0);
  109. ykjId.value = route.params.ykj_id;
  110. onMounted(() => {
  111. initData()
  112. })
  113. const school_id = ref("");
  114. const grade_id = ref("");
  115. const xueke_id = ref("");
  116. const initData =() => {
  117. let transObj = {
  118. school_id:school_id.value,
  119. cm_id: grade_id.value,
  120. xueke_id: xueke_id.value,
  121. jh_id: route.params.ykj_id,
  122. yscjd_rkjs: user.value.user_id,
  123. keyword:searchVal.value,
  124. page: pageNum.value,
  125. limit:10,
  126. }
  127. cjfx_slyf_list(transObj)
  128. .then(res => {
  129. if (res.code == "1") {
  130. tableData.value = res.data.tableData;
  131. totalPage.value = res.data.tableData.length;
  132. }
  133. })
  134. .catch(error=>{console.log(error)})
  135. }
  136. //option筛选
  137. const optionClick = (val: any, marke: any) => {
  138. if (marke == "scholl") {
  139. school_id.value = val;
  140. } else if (marke == "grade") {
  141. grade_id.value = val;
  142. } else {
  143. xueke_id.value = val;
  144. }
  145. initData();
  146. }
  147. //搜索
  148. const handleSearch = () => {
  149. initData();
  150. }
  151. //重置
  152. const restBtn = () => {
  153. school_id.value = '';
  154. grade_id.value ='';
  155. xueke_id.value = '';
  156. initData();
  157. }
  158. //导出
  159. const exportBtn = () => {
  160. let prefixedUrl = window.GLOBAL_CONFIG.web_pc;
  161. let fullUrl = prefixedUrl + '/openapi/echart/sfyl_data.php?api=xls&token=' + user.value.token;
  162. window.open(fullUrl,'_blank')
  163. }
  164. //弹出框
  165. const dialogTableVisible = ref(false)
  166. const openDialog = () => {
  167. dialogTableVisible.value = true;
  168. }
  169. </script>
  170. <style lang="scss" scoped>
  171. :deep(.el-input__wrapper) {
  172. height:40px;
  173. }
  174. :deep(.el-sub-menu__title) {
  175. background: #003eee;
  176. color: #fff;
  177. }
  178. :deep(.el-table__header thead tr th) {
  179. background: #003eee!important;
  180. color: #fff;
  181. height: 50px;
  182. line-height: 50px;
  183. font-weight: normal;
  184. }
  185. :deep(.el-table__header thead tr th:first-child) {
  186. border-top-left-radius: 9px;
  187. }
  188. :deep(.el-table__body tbody .el-table__row td) {
  189. background-color: transparent;
  190. }
  191. :deep(.el-dialog__footer) {
  192. text-align: center;
  193. }
  194. .blueBg {
  195. background: #F1F7FF;
  196. }
  197. .whiteBG {
  198. background: #fff;
  199. }
  200. .singlepart {
  201. background-color: rgba($color: #ffffff, $alpha: 0.2);
  202. color: #fff;
  203. }
  204. .listMain {
  205. min-height: 200px;
  206. max-height: 600px;
  207. overflow-y: auto;
  208. }
  209. .listMain_title {
  210. font-size: 14px;
  211. color: #fff;
  212. background: #003eee;
  213. overflow-y: auto;
  214. }
  215. .singleT {
  216. flex: 1;
  217. line-height: 50px;
  218. width: fit-content;
  219. text-align: center;
  220. }
  221. .singleD {
  222. flex: 1;
  223. }
  224. .singleTSec {
  225. width: fit-content;
  226. flex: 1;
  227. line-height: 60px;
  228. text-align: center;
  229. }
  230. .searchBtn{
  231. position:relative;
  232. }
  233. .searchBtnIcon{
  234. background-color: #0040EE;
  235. position:absolute;
  236. right:2%;
  237. top:50%;
  238. z-index:12;
  239. transform: translate(0,-9px);
  240. text-align:center;
  241. cursor: pointer;
  242. }
  243. .searchBtnIcon img{
  244. width:60%;
  245. height:60%;
  246. display:inline-block;
  247. }
  248. </style>